package com.xiao.sulingproduct.controller;

import com.xiao.sulingproduct.fegin.EsFeign;
import com.xiao.sulingpublic.to.ClassifyEsTo;
import com.xiao.sulingpublic.utils.R;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.io.IOException;

/**
 * @author: 1322127758@qq.com
 * @date: 2022/3/20 23:25
 * @作用:
 */
@RequestMapping("/sulingproduct/es")
@RestController
public class EsController {
    @Autowired
    private EsFeign esFeign;
    /**
     * 查询全部
     */
    @RequestMapping("/list")
    R list(@RequestBody ClassifyEsTo classifyEsTo) throws IOException {

        return esFeign.list(classifyEsTo);
    }
}
